package qingongjianxue;
class Student {
    private int Age;
    private String Name;
    private int Number;
    private String Sex;

    public Student(String n, int cage, int b, String x) {
        Name = n;
        if (Age < 0 || Age > 30) {
            Age = 18;
        } else {
            Age = cage;
        }
        Number = b;
        Sex = x;
    }

    public int getAge() {
        return Age;
    }

    public String getName() {
        return Name;
    }

    public int getNumber() {
        return Number;
    }

    public String getSex() {
        return Sex;
    }
}
